using System;
using System.Collections.Generic;
using System.Text;

namespace PDO.Utilities
{
    public class BasePDOException : BaseException
    {
        #region Private Static Readonly Members
        private static readonly Guid DEFAULT_APPLICATION_Guid = new Guid("ce3da750-6337-9ca2-b90d-33bac72051e2");
        private static readonly string DEFAULT_SUBSYSTEM = "General";
        #endregion

        #region Constructors
        /// <summary>
        /// Default Constructor for UIPolicyException
        /// </summary>
        public BasePDOException()
            : base()
        {
            //m_MessageForUser = new ErrorMessageInformation();

            SetUpPDOBaseException();
        } 


        /// <summary>
        /// Constructor for BasePDOException
        /// </summary>
        /// <param name="message">Exception Message</param>
        public BasePDOException(string message)
            : base(message)
        {
            SetUpPDOBaseException();
        }


        /// <summary>
        /// Constructor for BasePDOException
        /// </summary>
        /// <param name="message">Exception Message</param>
        /// <param name="innerEx">Inner Exception</param>
        public BasePDOException(string message, Exception innerEx)
            : base(message, innerEx)
        {
            SetUpPDOBaseException();
        }

        /// <summary>
        /// Default Constructor for BasePDOException
        /// </summary>
        /// <param name="user">User to log to</param>
        public BasePDOException(Guid user)
            : base()
        {
           // m_MessageForUser = new ErrorMessageInformation();
            m_User = user;
            SetUpPDOBaseException();
        }

        /// <summary>
        /// Constructor for BasePDOException
        /// </summary>
        /// <param name="message">Exception Message</param>
        /// <param name="user">User to log to</param>
        public BasePDOException(string message, Guid user)
            : base(message)
        {
            m_User = user;
            SetUpPDOBaseException();
        }

        /// <summary>
        /// Constructor for BasePDOException
        /// </summary>
        /// <param name="message">Exception Message</param>
        /// <param name="innerEx">Inner Exception</param>
        /// <param name="user">User to log to</param>
        public BasePDOException(string message, Exception innerEx, Guid user)
            : base(message, innerEx)
        {
            m_User = user;
            SetUpPDOBaseException();
        }

        
        #endregion

        #region Private Methods
        /// <summary>
        /// Used to set the Default application guid and subsystem for the application
        /// </summary>
        private void SetUpPDOBaseException()
        {
            m_ApplicationGuid = DEFAULT_APPLICATION_Guid;
            m_Subsystem = DEFAULT_SUBSYSTEM;
        }
        #endregion
    }
}
